// 2013-8-31下午02:28:31  net.betou.trade.main.dao.impl.PictureDaoImpl.java

package net.betou.trade.main.dao.impl;

import net.betou.common.hibernate3.HibernateBaseDao;
import net.betou.trade.entity.main.Picture;
import net.betou.trade.main.dao.PictureDao;

import org.springframework.stereotype.Repository;

/**
 * 
 * @author 叶装装
 */
@Repository
public class PictureDaoImpl extends HibernateBaseDao< Picture, Integer > implements PictureDao{

	@Override
	protected Class< Picture > getEntityClass( ) {
		return Picture.class;
	}

	public Picture delete( Picture p ) {
		if( p != null ){
			getSession( ).delete( p );
		}
		return p;
	}

	public Picture save( Picture p ) {
		getSession( ).save( p );
		return p;
	}
	
	public Picture findById( Integer id ){
		return get( id );
	}

}
